import calendar
import tkinter as tk
root = tk.Tk()
labels = [['一','二','三','四','五','六','日']]
mo = calendar.monthcalendar(2022,3)
for i in range(len(mo)):
    labels.append(mo[i])
for r in range(len(labels)):
    for c in range(7):
        if labels[r][c] == 0:
            labels[r][c] = '  '
        l = tk.Label(root,padx=4,pady=5,text=labels[r][c])
        l.grid(row=r, column=c)
root.mainloop()



